﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace IM.Easy.Workflow.IServices
{
    /// <summary>
    /// 
    /// </summary>
    public interface IWorkflowService
    {
        /// <summary>
        /// 启动一个新的工作流实例
        /// </summary>
        Task<string> StartWorkflowAsync(string workflowId, int version, object data);

        ///// <summary>
        ///// 挂起工作流实例
        ///// </summary>
        //Task<bool> SuspendWorkflowAsync(string instanceId);

        ///// <summary>
        ///// 恢复挂起的工作流实例
        ///// </summary>
        //Task<bool> ResumeWorkflowAsync(string instanceId);

        ///// <summary>
        ///// 终止工作流实例
        ///// </summary>
        //Task<bool> TerminateWorkflowAsync(string instanceId);

        ///// <summary>
        ///// 发布外部事件触发挂起的工作流
        ///// </summary>
        //Task PublishEventAsync(string eventName, string eventKey, object eventData);
    }
}
